Pre-processing
Load packages
library(Seurat)
library(Signac)
library(flexclust)
library(tidyverse)
library(plyr)
library(harmony)
library(class)
library(ggplot2)
library(reshape2)
Parameters
path_to_save_annotated_citeseq <- "/home/srashmi/Documents/tonsil_atlas_citeseq_vdj_20210505/10-sub_cluster_annotation/PC_differential/objects/PC_tonsil_cite_seq_annotated.rds"
color <- c("black", "gray", "red", "yellow", "violet", "green4",
"blue", "mediumorchid2", "coral2", "blueviolet",
"indianred4", "deepskyblue1", "dimgray", "deeppink1",
"greenyellow", "lightgray", "hotpink1", "chocolate", "aquamarine", "aliceblue", "burlywood", "blueviolet", "indianred", "gold","coral", "orangered")
Variables
Load data
seurat_citeseq <- readRDS(path_to_save_annotated_citeseq)
DefaultAssay(seurat_citeseq) <- "ADT"
Idents(seurat_citeseq) <- seurat_citeseq@meta.data$PC_annotation_level_5
GZ-LZ vs PC commited
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "GC-LZ", ident.2 = "PC committed GC-LZ", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

GZ-LZ vs IgG+ PC precursor
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "GC-LZ", ident.2 = "IgG+ PC precursor", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

GZ-LZ vs Pre-Mature IgG+ PC
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "GC-LZ", ident.2 = "Pre-Mature IgG+ PC", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

##
## $`2`

GZ-LZ vs Mature PC (“MBC-derived IgG+ PC”, “MBC-derived IgA+ PC”, “Mature IgM+ PC”, “Mature IgG+ PC”, “Mature IgA+ PC”)
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "GC-LZ", ident.2 = c("MBC-derived IgG+ PC", "MBC-derived IgA+ PC", "Mature IgM+ PC", "Mature IgG+ PC", "Mature IgA+ PC"), min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

##
## $`2`

##
## $`3`

##
## $`4`

PC committed GC-LZ vs IgG+ PC precursor
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "PC committed GC-LZ", ident.2 = "IgG+ PC precursor", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

PC committed GC-LZ vs Pre-Mature IgG+ PC
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "PC committed GC-LZ", ident.2 = "Pre-Mature IgG+ PC", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

##
## $`2`

##
## $`3`

PC committed GC-LZ vs Mature PC (“MBC-derived IgG+ PC”, “MBC-derived IgA+ PC”, “Mature IgM+ PC”, “Mature IgG+ PC”, “Mature IgA+ PC”)
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "PC committed GC-LZ", ident.2 = c("MBC-derived IgG+ PC", "MBC-derived IgA+ PC", "Mature IgM+ PC", "Mature IgG+ PC", "Mature IgA+ PC"), min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

##
## $`2`

##
## $`3`

##
## $`4`

##
## $`5`

IgG+ PC precursor vs Pre-Mature IgG+ PC
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "IgG+ PC precursor", ident.2 = "Pre-Mature IgG+ PC", min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

IgG+ PC precursor vs Mature PC (“MBC-derived IgG+ PC”, “MBC-derived IgA+ PC”, “Mature IgM+ PC”, “Mature IgG+ PC”, “Mature IgA+ PC”)
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "IgG+ PC precursor", ident.2 = c("MBC-derived IgG+ PC", "MBC-derived IgA+ PC", "Mature IgM+ PC", "Mature IgG+ PC", "Mature IgA+ PC"), min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`

##
## $`2`

Pre-Mature IgG+ PC vs Mature PC (“MBC-derived IgG+ PC”, “MBC-derived IgA+ PC”, “Mature IgM+ PC”, “Mature IgG+ PC”, “Mature IgA+ PC”)
markers <- FindMarkers(object = seurat_citeseq, ident.1 = "Pre-Mature IgG+ PC", ident.2 = c("MBC-derived IgG+ PC", "MBC-derived IgA+ PC", "Mature IgM+ PC", "Mature IgG+ PC", "Mature IgA+ PC"), min.pct = 0.25)
DT::datatable(markers)
DoHeatmap(seurat_citeseq, features = unique(rownames(markers)), label = F)

## $`0`

##
## $`1`
